clc; clear; close all;

SumStats    = zeros(3,5);
RowHeadings = {'Royal Dutch/Shell','Smithkline/Beecham','Rio Tinto PLC/Ltd'};
ColHeadings = {'Mean', 'Standard Deviation', 'P10','Median','P90'};
%Run through each currency and store the values in the appropriate row and
%column based on the row headings and column headings hard coded above

%The values are the ratio of the shares, adjusted for value (1 is parity
%predicted by frictionless models)

load('intermediate\workspace_RDShell.mat')
SumStats(1,:)=[mean(ratios) std(ratios) prctile(ratios,10) prctile(ratios,50) prctile(ratios,90)];

load('intermediate\workspace_Smithkline.mat')
SumStats(2,:)=[mean(ratios) std(ratios) prctile(ratios,10) prctile(ratios,50) prctile(ratios,90)];

load('intermediate\workspace_RioTinto.mat')
SumStats(3,:)=[mean(ratios) std(ratios) prctile(ratios,10) prctile(ratios,50) prctile(ratios,90)];

save('output\summary_stats_twin_shares','SumStats','ColHeadings','RowHeadings');